<link href="/css/list-all.css" rel="stylesheet"  media="screen">
<div id="search" class="row">
  <% if (!packages.length) { %>
    <div class="ant-alert ant-alert-warn">
    当前私有库未发布任何包
    </div>
  <% } %>
  <% if (packages.length) { %>
    <div class="col-24">
    <table>
      <thead>
        <tr>
          <th>包</th>
          <th>最新版本</th>
          <th>作者</th>
          <th>更新日期</th>
          <th>描述</th>
        </tr>
      </thead>
      <tbody>
        <% for (var i = 0; i < packages.length; i++) {
          var item = packages[i];
        %>
        <tr>
          <td><a href="/package/<%= item.name %>"><%= item.name %></a></td>
          <td><%= item.version%></td>
          <td><a href="/u/<%= item.author%>"><%= item.author%></a></td>
          <td><%= formatDate(item.gmt_modified)%></td>
          <td><span class="package-description"><%= item.description %></span></td>
        </tr>
        <% } %>
      </tbody>
    </table>
  </div>
  <% } %>

  <div class="col-24">
    <span>总共:<%= total.doc_count%> 个库</span>
    <div class="pagination">
        <% for (var i = 1; i < total.totalPage+1; i++) {%>
        <a href="/list/page/<%= i%>" class="page gradient"><%= i%></a>
        <%}%>
	</div>
   
  </div>
</div>
